package vn.fpt.fsoft.entities;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * ThongNV2
 */

@Entity
@Table(name = "Programme")
public class Programme implements java.io.Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 4434937285874323424L;
	private int programmeId;
	private Contact contact;
	private String programmeName;
	private String description;
	private Boolean status;

	public Programme() {
	}

	public Programme(int programmeId) {
		this.programmeId = programmeId;
	}

	public Programme(int programmeId, Contact contact,
			String programmeName, String description, Boolean status) {
		this.programmeId = programmeId;
		this.contact = contact;
		this.programmeName = programmeName;
		this.description = description;
		this.status = status;
	}

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "ProgrammeId")
	public int getProgrammeId() {
		return this.programmeId;
	}

	public void setProgrammeId(int programmeId) {
		this.programmeId = programmeId;
	}

	@ManyToOne(fetch=FetchType.LAZY)
	@JoinColumn(name="ContactId",nullable=true)
	public Contact getContact() {
		return this.contact;
	}

	public void setContact(Contact contact) {
		this.contact = contact;
	}

	@Column(name = "ProgrammeName", nullable = true, length = 50)
	public String getProgrammeName() {
		return this.programmeName;
	}

	public void setProgrammeName(String programmeName) {
		this.programmeName = programmeName;
	}

	@Column(name = "Description")
	public String getDescription() {
		return this.description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	@Column(name = "Status")
	public Boolean getStatus() {
		return this.status;
	}

	public void setStatus(Boolean status) {
		this.status = status;
	}

}
